#!/usr/bin/Rscript
# _*_ coding: utf-8 _*_

library(ggtree)

args <- commandArgs()

tree_file_path<-args[6]
# 标记单个样本
label_name<-args[7]

png(filename = paste(c(tree_file_path, label_name, 'png'), collapse='.'), width = 10, height = 10, units = 'in', bg = 'white', res = 300)

tree = read.tree(tree_file_path)

tree_obj = ggtree(tree, layout = "circular", branch.length='none')

tree_obj+geom_tippoint(aes(color = label == label_name)) +
scale_color_manual(values = c("grey", "red")) +
theme_tree(legend.position = "none")

dev.off()
